package com.caldremch.jnidemo;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.widget.TextView;

import com.caldremch.caldremcore.CalCore;

public class MainActivity extends AppCompatActivity {

    public static final String TAG = "caldremch";

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        ((TextView)findViewById(R.id.tv_jni)).setText(CalCore.getStringFromJni());

        CalCore c = new CalCore();
//        c.createGlobalRef();
//        Log.e(TAG, "全局str="+c.getGlobalRef());
//        c.deteleGlobalRef();
//        Log.e(TAG, "全局str="+c.getGlobalRef());

//        for (int i = 0; i < 100; i++) {
//            c.testcache();
//        }

    }
}
